﻿<%@ Page Title="" Language="VB" MasterPageFile="~/MainLayout.master" AutoEventWireup="false" CodeFile="propertytnotsalerent.aspx.vb" Inherits="propertytnotsalerent" %>
<%@ Register assembly="AjaxControlToolkit" namespace="AjaxControlToolkit" tagprefix="cc1" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
<script type="text/javascript" src="scripts/overlib.js"></script>
<asp:Label ID="lblUserID" runat="server" Visible="false" />
<asp:Label ID="lblStaffType" runat="server" Visible="false" />
<div >
    <h1>Property List</h1>
<hr />
    <div  runat="server" id="divError" class="msg-box-error" visible="false" enableviewstate="false">
        <span class="title">Error</span><br />
        <asp:Label ID="lblMsgError" runat="server" Text="ERROR" />
    </div>
    <div  runat="server" id="divSuccessful" class="msg-box-success" visible="false" enableviewstate="false">
        <span class="title">Successful</span><br />
        <asp:Label ID="lblMsgSuccessful" runat="server" Text="Success" />
    </div>
    
    <table class="searchbox" cellpadding="0" cellspacing="0" width="100%">
        <tr>
            <td valign="bottom"><%--<div class="header"><asp:ImageButton ID="imgNewListing" runat="server" ImageUrl="~/images/style01/AddNewButton-Listing.png" Width="80" Height="20" AlternateText=" Add New Listing" /><img src="images/style01/search-box-divider.gif" width="2" height="20" class="search-divider"/></div>--%></td>
            <td align="right"><%--<asp:TextBox ID="txtSearch" runat="server" /><asp:Button ID="btnSearch" runat="server" Text="Search" />--%>
            </td>
            <td width="150px" align="center" valign="bottom"><asp:Panel ID="pnlCollapse" runat="server" CssClass="collapsePanelHeader" Height="20px"><img src="images/style01/search-box-divider.gif" width="2" height="20" class="search-divider" style="float:left;" /><asp:ImageButton ID="imgButExpand" runat="server" ImageUrl="~/images/style01/Btn-Expand.png"  Height="20" Width="50" AlternateText="Advanced Search"/></asp:Panel></td>
        </tr>
    </table>
    
    <!--Slide Out Adv Search Here-->
<asp:Panel ID="pnlFilter" runat="server" CssClass="collapsePanel" Height="0">


<table class="SearchFilter" width="100%" border="0" cellspacing="0" cellpadding="0">
<tbody>
  <tr>
    <td width="30">&nbsp;</td>
    <td width="120">Project</td>
    <td width="250"><asp:TextBox ID="txtProject" runat="server" Width="300px" /></td>
    <td width="30">&nbsp;</td>
    <td width="120">Property Type</td>
    <td width="250">
    
    <asp:UpdatePanel ID="upePropertyType" runat="server" UpdateMode="Always"><ContentTemplate>
            <asp:TextBox ID="txtPropertyType" runat="server" Width="250px" />
            <%--Project Type Entry Panel--%>
            <asp:Panel ID="pnlPropertyTypeEntry" runat="server" CssClass="modalPopup" 
                Style="display:none" Width="500px">
                <table border="0" cellpadding="0" cellspacing="0" class="PopupContainer">
        <tr>
            <td style="width:30px; height:41px" background="images/style01/PopupHead-top-left.gif">
            </td>
            <td background="images/style01/PopupHead-top-middle.gif" valign="bottom">
                <table width="100%" border="0" cellpadding="0" cellspacing="0" class="PopupHeader">
                <thead>
                    <tr>
                        <td align="center" style="text-align:center" height="30"><asp:Label ID="lblPropertyEntryTitle" runat="server" Text="Property Type Detail" /></td>
                        <td align="right" style="text-align:right"><asp:ImageButton ID="imgButPropertyTypeClose" runat="server" AlternateText="Close" Height="20px" Width="20px" ImageUrl="~/images/style01/Btn-Close.png"  /> </td>
                    </tr>
                 </thead>
                </table>    
            </td>
            <td style="width:30px; height:41px" background="images/style01/PopupHead-top-right.gif">
            </td>
        </tr>
        <tr>
        <td width="30" height="30" background="images/style01/Popup-PropertyType-left.gif">&nbsp;</td>
        <td  background="images/style01/Popup-PropertyType-middle.gif" style="background-color:white;">&nbsp;</td>
        <td background="images/style01/Popup-PropertyType-right.gif">&nbsp;</td>
        </tr>
        <tr>
            <td style="width:30px" background="images/style01/Popup-left-middle.gif"></td>
            <td  bgcolor="#FFFFFF" >
                <table width="100%" border="0" cellpadding="0" cellspacing="0" class="PopupDataDisplay" style="height:100%; background-color:#FFFFFF;" >
                    <tr>
                        <td >
                        <div style="height:500px; overflow:auto;">
                                <table width="100%" border="0"  >
                                    <tr>
                                        <td>
                                            <strong>Property Type</strong></td>
                                        <td>
                                            <strong>Description</strong></td>
                                    </tr>
                                    <asp:Repeater ID="repPropertyType" runat="server">
                                        <ItemTemplate>
                                            <tr>
                                                <td>
                                                    <asp:LinkButton ID="lnkRepPropertyType" runat="server" 
                                                        CommandArgument='<%# DataBinder.Eval(Container,"ItemIndex") %>' 
                                                        CommandName="SelectType" Text='<%#Container.DataItem("Type").ToString%>' />
                                                </td>
                                                <td>
                                                    <%#Container.DataItem("TypeDesc").ToString%>
                                                </td>
                                            </tr>
                                        </ItemTemplate>
                                    </asp:Repeater>
                                </table>
                            </div>
                        
                        
                        
                        
                        </td>
                    </tr>
                </table>
            </td>
            
            <td style="width:30px" background="images/style01/Popup-right-middle.gif"></td>
        </tr>
        <tr>
            <td style="width:30px; height:55px" background="images/style01/Popup-bottom-left.gif"></td>
            <td style="text-align:right" background="images/style01/Popup-bottom-middle.gif">&nbsp;</td>
            <td style="width:30px; height:55px" background="images/style01/Popup-bottom-right.gif"></td>
        </tr>
    </table>

            </asp:Panel>
            <asp:Button ID="btnPropertyTypeHiddenNew" runat="server" style="display:none" />
            <cc1:ModalPopupExtender ID="mpePropertyTypeEntry" runat="server" BackgroundCssClass="modalBackground" DropShadow="false" PopupControlID="pnlPropertyTypeEntry" TargetControlID="btnPropertyTypeHiddenNew" EnableViewState="True" />
            <%--End Project Type Entry Panel--%>
            </ContentTemplate></asp:UpdatePanel>

    </td>
    <td>
        <asp:ImageButton ID="btnSearchPropertyType" runat="server" Text="Search" ImageUrl="~/images/style01/Btn-manify.png" />
      </td>
      <td>&nbsp;</td>
  </tr>
  <tr>
    <td>&nbsp;</td>
    <td>Road Name</td>
    <td><asp:TextBox ID="txtRoadName" runat="server" Width="300px" /></td>
    <td>&nbsp;</td>
    <td>List Type</td>
    <td>
        <asp:DropDownList ID="ddlListType" runat="server">
            <asp:ListItem Selected="True" Text="SR - Sales Residential" Value="0" />
            <asp:ListItem Text="SC - Sales Commercial" Value="1" />
            <asp:ListItem Text="SI - Sales Industrial" Value="2" />
            <asp:ListItem Text="SL - Sales Land" Value="3" />
            <asp:ListItem Text="RR - Rent Residential" Value="4" />
            <asp:ListItem Text="RC - Rent Commercial" Value="5" />
            <asp:ListItem Text="RI - Rent Industrial" Value="6" />
            <asp:ListItem Text="RL - Rent Land" Value="7" />
        </asp:DropDownList>
        <%--<asp:DropDownList ID="ddlListType" runat="server">
            <asp:ListItem Selected="True" Text="Not For Sale" Value="0" />
            <asp:ListItem Text="Sold By Owner" Value="1" />
            <asp:ListItem Text="Not For Rent" Value="2" />
            <asp:ListItem Text="Rent By Owner" Value="3" />
        </asp:DropDownList>--%>
      </td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>&nbsp;</td>
    <td>Location Name</td>
    <td><asp:TextBox ID="txtLocationName" runat="server" Width="300px" /></td>
    <td>&nbsp;</td>
    <td><%--List Status--%>Status</td>
    <td><asp:DropDownList ID="ddlListStatus" runat="server" Visible="false" >
                <asp:ListItem Text="ANY" Value="0" Selected="True" />
                <asp:ListItem Text="New" Value="1" />
                <asp:ListItem Text="Updated" Value="2" />
                <asp:ListItem Text="Old" Value="3" />
            </asp:DropDownList>
        <asp:DropDownList ID="ddlStatus" runat="server">
            <asp:ListItem Selected="True" Text="Not For Sale" Value="0" />
            <asp:ListItem Text="Sold By Owner" Value="1" />
            <asp:ListItem Text="Not For Rent" Value="2" />
            <asp:ListItem Text="Rent By Owner" Value="3" />
            <%--<asp:ListItem Text="Deleted" Value="4" />--%>
        </asp:DropDownList>
    </td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>&nbsp;</td>
    <td>Unit Number</td>
    <td><asp:TextBox ID="txtUnitNumber" runat="server" Width="300px" /></td>
    <td>&nbsp;</td>
    <td>Price</td>
    <td><asp:TextBox ID="txtPriceFrom" runat="server" Width="100px" Text="0" onkeypress="return isNumberKey(event)" onpaste="return false;" />&nbsp;TO&nbsp;<asp:TextBox ID="txtPriceTo" runat="Server" Width="100px" Text="999999999" onkeypress="return isNumberKey(event)" onpaste="return false;" /></td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>&nbsp;</td>
    <td>Country</td>
    <td><asp:DropDownList ID="ddlCountry" runat="server" AutoPostBack="true" Width="300px"/></td>
    <td>&nbsp;</td>
    <td>Price PSF</td>
    <td><asp:TextBox ID="txtPricePSFFrom" runat="server" width="100px" Text="0" onkeypress="return isNumberKey(event)" onpaste="return false;" />&nbsp;TO&nbsp;<asp:TextBox ID="txtPricePSFTo" runat="server" Width="100px" Text="999999999" onkeypress="return isNumberKey(event)" onpaste="return false;" /></td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
    <tr>
    <td>&nbsp;</td>
    <td>State</td>
    <td><asp:DropDownList ID="ddlState" runat="server" Width="300px" /></td>
    <td>&nbsp;</td>
    <td><%--Best Buy--%>&nbsp;</td>
    <td>
        <asp:DropDownList ID="ddlBestBuy" runat="server" Width="50px" Visible="false">
            <asp:ListItem Selected="True" Text="ANY" Value="3" />
            <asp:ListItem Text="Yes" Value="1" />
            <asp:ListItem Text="No" Value="0" />
        </asp:DropDownList>
        </td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
    <tr>
    <td>&nbsp;</td>
    <td>List By</td>
    <td><asp:DropDownList ID="ddlListBy" runat="server" Width="300px" /></td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
    <tr>
    <td>&nbsp;</td>
    <td colspan="5" align="right"><div style="border-top: 1px solid #c2c2c2; height:20px; padding-top:10px; "><asp:Button ID="btnSearch" runat="server" Text="Search" CssClass="search-btn" Width="80" />    
        <asp:Button ID="btnResetSearchFilter" runat="server" Text="Reset" CssClass="search-btn" Width="60" /></div>
    </td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
  </tbody>

</table>

<br />

<!--Result Pane Here-->

</asp:Panel>
<cc1:CollapsiblePanelExtender ID="cpeDemo" runat="Server"
        TargetControlID="pnlFilter"
        ExpandControlID="pnlCollapse"
        CollapseControlID="pnlCollapse" 
        Collapsed="False"
        ImageControlID="imgButExpand"    
        ExpandedImage="~/images/style01/Btn-Collapsed.png"
        CollapsedImage="~/images/style01/Btn-Expand.png"
        SuppressPostBack="true" />
<table class="ResultPanelContainer" border="0" cellpadding="0" cellspacing="0" width="100%">
    <tr>
        <td>
        
            <table class="ResultPanelHeader" border="0" width="100%">
                <tr>
                    <td><asp:label ID="lblHeadNoOfItem" runat="server" text="0" />&nbsp;items total</td>
                    <td align="right">
                        Number of entries per page : <asp:LinkButton ID="lnkHead10Item" runat="server" Text="10" />&nbsp;<asp:LinkButton ID="lnkHead25Item" runat="server" Text="25" />&nbsp;<asp:LinkButton ID="lnkHead100Item" runat="server" Text="100" />&nbsp;<asp:LinkButton ID="lnkHead150Item" runat="server" Text="150" />
                    </td>
                </tr>
            </table>
        </td>
    </tr>
    <tr>
        <td>
           
            <table width="100%" border="0" cellpadding="0" cellspacing="0" class="ResultPanelDataDisplay" id="PropertyList">
            <thead >
                <tr>
                    <th scope="col" id="first-col"><strong><asp:LinkButton ID="lnkUnitNo" runat="server" Text="Unit No▲" ForeColor="Black" style="text-decoration:none" /></strong></th>
                    <th scope="col"><strong><asp:LinkButton ID="lnkRoad" runat="server" Text="Road▲" ForeColor="Black" style="text-decoration:none" /></strong></th>
                    <th scope="col"><strong><asp:LinkButton ID="lnkLocation" runat="server" Text="Location▲" ForeColor="Black" style="text-decoration:none" /></strong></th>
                    <th scope="col"><strong><asp:LinkButton ID="lnkState" runat="server" Text="State▲" ForeColor="Black" style="text-decoration:none" /></strong></th>
                    <th scope="col"><strong><asp:LinkButton ID="lnkCountry" runat="server" Text="Country▲" ForeColor="Black" style="text-decoration:none;display:none;" /></strong></th>
                    <th scope="col"><strong><asp:LinkButton ID="lnkProject" runat="server" Text="Project▲" ForeColor="Black" style="text-decoration:none" /></strong></th>
                    <th scope="col"><strong><asp:LinkButton ID="lnkType" runat="server" Text="Project Type▲" ForeColor="Black" style="text-decoration:none" /></strong></th>
                    <th scope="col"><strong><asp:LinkButton ID="lnkAmt" runat="server" Text="Price▲" ForeColor="Black" style="text-decoration:none" /></strong></th>
                    <th scope="col"><strong><asp:LinkButton ID="lnkName" runat="server" Text="Lister▲" ForeColor="Black" style="text-decoration:none" /></strong></th>
                    <th scope="col"><strong><asp:LinkButton ID="lnkCreateDate" runat="server" Text="List Date▲" ForeColor="Black" style="text-decoration:none" /></strong></th>
                    <th scope="col"><strong><asp:LinkButton ID="lnkUpdateWho" runat="server" Text="Updated By▲" ForeColor="Black" style="text-decoration:none" /></strong></th>
                    <th scope="col"><strong><asp:LinkButton ID="lnkUpdateDate" runat="server" Text="Last Modifited Date▲" ForeColor="Black" style="text-decoration:none" /></strong></th>
                    <th scope="col"><strong><asp:LinkButton ID="lnkRelistStatus" runat="server" Text="Status▲" ForeColor="Black" style="text-decoration:none" /></strong></th>
                    <th scope="col" style="display:none"><strong><asp:Label ID="lblRentSaleStatus" runat="server" /> <asp:LinkButton ID="lnkOtherRelistStatus" runat="server" Text="Status▲" ForeColor="Black" style="text-decoration:none" /></strong></th>
                   <%-- <th scope="col">&nbsp;</th>--%>
                    <th scope="col">&nbsp;</th>
                    <th scope="col">&nbsp;</th>
                </tr>
            </thead> 
            <tbody>
                <asp:Repeater ID="repProperty" runat="server">
                    <ItemTemplate>
                        <tr style="background-color:<%#Container.dataitem("ColColor").tostring %>">
                        <%--edited by minginn @13/4/11 to allow user view the property by clicking the row--%>
                            <td id="first-col"><asp:Label ID="lblRepPropertyUID" runat="server" Text='<%#Container.dataitem("PropertyId").tostring %>' Visible="false" /><asp:LinkButton ID="lblRepUnitNumber" runat="server" Text='<%#Container.DataItem("UnitNumber").ToString%>' CommandArgument='<%#Container.dataitem("OId").tostring %>' CommandName="ViewList" /></td>
                                <td><asp:LinkButton ID="lblRepRoad" runat="server" Text='<%#Container.dataitem("Road").tostring %>' CommandArgument='<%#Container.dataitem("OId").tostring %>' CommandName="ViewList" /></td>
                                <td><asp:LinkButton ID="lblRepLocation" runat="server" Text='<%#Container.dataitem("Location").tostring %>' CommandArgument='<%#Container.dataitem("OId").tostring %>' CommandName="ViewList" /></td>
                                <td><asp:LinkButton ID="lblRepState" runat="server" Text='<%#Container.dataitem("State").tostring %>' CommandArgument='<%#Container.dataitem("OId").tostring %>' CommandName="ViewList" /></td>
                                <td><asp:LinkButton ID="lblRepCountry" runat="server" Text='<%#Container.dataitem("Country").tostring %>' CommandArgument='<%#Container.dataitem("OId").tostring %>' CommandName="ViewList" style="display:none" /></td>
                                <td><asp:LinkButton ID="lblRepProject" runat="server" Text='<%#Container.dataitem("Project").tostring %>'  onmouseout="return nd();" style="cursor: pointer;" CommandArgument='<%#Container.dataitem("OId").tostring %>' CommandName="ViewList"/><asp:Label ID="lblRepProjectDesc" runat="server" Text='<%#Container.dataitem("ProjectDesc").tostring %>' Visible="false" /><asp:Label ID="lblRepProjectPIcture" runat="server" Text='<%#Container.DataItem("Picture").Tostring %>' Visible="false" /></td>
                                <td><asp:LinkButton ID="lblRepProjectType" runat="server" Text='<%#Container.dataitem("Type").tostring %>' onmouseout="return nd();" style="cursor: pointer;" CommandArgument='<%#Container.dataitem("OId").tostring %>' CommandName="ViewList" /><asp:Label ID="lblRepTypeDesc" runat="server" Text='<%#Container.dataitem("TypeDesc").tostring %>' Visible="false" /></td>
                                <td><asp:LinkButton ID="lblRepPrice" runat="server" Text='<%#Bind("Amt","{0:#,##0.00}") %>' CommandArgument='<%#Container.dataitem("OId").tostring %>' CommandName="ViewList" /></td>
                                <td><asp:LinkButton ID="lblRepLister" runat="server" Text='<%#Container.dataitem("Name").tostring %>' CommandArgument='<%#Container.dataitem("OId").tostring %>' CommandName="ViewList" /><asp:Label ID="lblRepListerID" runat="server" Text='<%#Container.dataitem("StaffId").tostring %>' Visible="false" /></td>
                                <td><asp:LinkButton ID="lblRepListDate" runat="server" Text='<%# Bind("CreateDated","{0:dd-MMM-yyyy}") %>' CommandArgument='<%#Container.dataitem("OId").tostring %>' CommandName="ViewList" /></td>
                                <td><asp:LinkButton ID="lblRepLastUpdateBy" runat="server" Text='<%#Container.dataitem("UpdateWho").tostring %>' CommandArgument='<%#Container.dataitem("OId").tostring %>' CommandName="ViewList" /></td>
                                <td><asp:LinkButton ID="lblRepLastUpdate" runat="server" Text='<%# Bind("UpdateDate","{0:dd-MMM-yyyy}") %>' CommandArgument='<%#Container.dataitem("OId").tostring %>' CommandName="ViewList" /></td>
                                <td><asp:Label ID="lblRepCurrentStatus" runat="server" Text='<%#Container.dataitem("RelistStatus").tostring %>' Visible="false"/><asp:LinkButton ID="lblRepRelistStr" runat="server" CommandArgument='<%#Container.dataitem("OId").tostring %>' CommandName="ViewList" /></td>
                                <td style="display:none"><asp:Label ID="lblRepOtherStatus" runat="server" Text='<%#Container.dataitem("OtherRelistStatus").tostring %>' visible="false"/><asp:LinkButton ID="lblRepOtherRelistStr" runat="server" CommandArgument='<%#Container.dataitem("OId").tostring %>' CommandName="ViewList" /></td>
                               <%-- <td><asp:ImageButton ID="imgbutView" runat="server" AlternateText="View" CommandArgument='<%#Container.dataitem("PropertyId").tostring %>' CommandName="ViewList" ImageUrl="~/images/style01/ViewButton.png"/></td>--%>
                                <td style="display:none"><asp:ImageButton ID="imgbutEdit" runat="server" AlternateText="Edit" CommandArgument='<%#Container.dataitem("PropertyId").tostring %>' CommandName="EditList" ImageUrl="~/images/style01/EditButton.png"/></td> 
                                <td>&nbsp;</td> 
                        </tr>
                    </ItemTemplate>
                </asp:Repeater>
               </tbody>
            </table>
            
      </td>
    </tr>
    <tr>
        <td>
            <table class="ResultPanelFooter" width="100%">
                <tr>
                    <td ><asp:label ID="lblFootNoOfItem" runat="server" text="0" />&nbsp; items total</td>
                    <td align="center" valign="middle">
                        <asp:Panel ID="pnlNavigation" runat="server" style="text-align:center; vertical-align:middle;">
                                <asp:ImageButton ImageUrl="images/style01/Btn-jump-first.png"   ID="btnMoveFirst"  runat="server" Width="28"  Height="18" style="vertical-align:middle;"/>&nbsp;
                                <asp:ImageButton ImageUrl="images/style01/Btn-jump-back.png"    ID="btnPrevious"   runat="server" Width="28"  Height="18" style="vertical-align:middle;"/>&nbsp;
                                <asp:TextBox ID="txtPageNo" runat="server" Text="1" Height="12" Width="28" Font-Size="10px" style="text-align:center; vertical-align:middle;" onkeypress="return isNumberKeyOnly(event)" onpaste="return isNumberKeyOnly(event)" />&nbsp;
                                <asp:Label ID="lblTotalPage" runat="server" Height="20" Font-Size="10px" style="vertical-align: middle;"/>&nbsp;
                                <asp:ImageButton ImageUrl="images/style01/Btn-jump-go.png"      ID="btnGo"          runat="server"  Width="28" Height="18" style="vertical-align:middle;"/>&nbsp;
                                <asp:ImageButton ImageUrl="images/style01/Btn-jump-foward.png"  ID="btnNext"        runat="server"  Width="28" Height="18" style="vertical-align:middle;"/>&nbsp;
                                <asp:ImageButton ImageUrl="images/style01/Btn-jump-last.png"    ID="btnMoveLast"    runat="server"  Width="28" Height="18" style="vertical-align:middle;"/>
                                <asp:Label ID="lblMaxPageCount" runat="server" Visible="false" Height="20" Font-Size="10px" style="vertical-align:middle;"/>
                      </asp:Panel>
                    </td>
                    <td align="right">
                        Number of entries per page : <asp:LinkButton ID="lnkFoot10Item" runat="server" Text="10" />&nbsp;<asp:LinkButton ID="lnkFoot25Item" runat="server" Text="25" />&nbsp;<asp:LinkButton ID="lnkFoot100Item" runat="server" Text="100" />&nbsp;<asp:LinkButton ID="lnkFoot150Item" runat="server" Text="150" />
                    </td>
                </tr>
            </table>
        </td>
    </tr>
</table>

<asp:Label ID="lblhidSortType" runat="server" Visible="false" Text="ORDER BY UpdateDate DESC, CreateDated DESC, UnitNumber DESC, Road DESC, Location DESC, State DESC, Country DESC, Project DESC, Type DESC, Amt DESC, Name DESC, UpdateWho DESC, RelistStatus DESC, OtherRelistStatus DESC" />
</div>
</asp:Content>

